package com.agiantii.ablog.handler.article.filter;

import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
import org.springframework.stereotype.Component;

@Component
public class FilterCollection implements Collection<ContentFilter> {
    private final List<ContentFilter> filters = new ArrayList<>();
    
    public void addFilter(ContentFilter filter) {
        filters.add(filter);
    }
    
    @Override
    public Iterator<ContentFilter> createIterator() {
        return filters.iterator();
    }
    
    @Override
    public int size() {
        return filters.size();
    }
    
    public void clear() {
        filters.clear();
    }
} 